<template>
  <div class="store">
    <div class="top">
      <div class="title">
        <div class="item bond">{{seller.name}}</div>
        <div class="item">月销量 {{seller.sellCount}} 单</div>
      </div>
      <div class="data">
        <div class="item">
          <div>起送价</div>
          <div><span>{{seller.minPrice}}&nbsp;</span>元</div>
        </div>
        <div class="item">
          <div>商家配送</div>
          <div><span>{{seller.deliveryPrice}}&nbsp;</span>元</div>
        </div>
        <div class="item">
          <div>平均配送时间</div>
          <div><span>{{seller.deliveryTime}}&nbsp;</span>分钟</div>
        </div>
      </div>
    </div>

    <div class="content">
      <div class="bond">公告与活动</div>
      <ul>
        <li v-for="(item,index) of seller.supports" :key="index"><i class="el-icon-finished"></i>&nbsp;&nbsp;{{item.description}}</li>
      </ul>
    </div>

    <div class="pic">
      <div class="bond">商家实景</div>
      <div class="imgbox">

      <img v-for="(item,index) of seller.pics" :key="index" :src="item" alt="">
      </div>
    </div>
  </div>
</template>

<script>
export default {
  name: "Store",
  methods: {
    swiperup() {
      console.log(4444);
    },
    swiperright() {
      console.log(8888);
    },
  },
  computed:{
    seller(){
      return this.$store.state.getDataAbout.data.seller
    }
  },
  activated() {
    console.log(this.seller.supports)
  },
};
</script>

<style scoped>
.store {
  background: #eee;
  font-size: 12px;
}
.top {
  height: 120px;
  padding: 5px 20px 10px 20px;
  border-bottom: 1px solid #ddd;
  background: #fff;
}
.top .title {
  padding: 8px 0;
  height: 50px;
  border-bottom: 1px solid #ddd;
  display: flex;
  flex-direction: column;
  justify-content: space-around;
}
.top .data {
  display: flex;
  height: 60px;
  justify-content: space-around;
  align-items: center;
}
.top .data .item {
  text-align: center;
}
.top .data .item span {
  font-size: 19px;
}

.content {
  margin-top: 20px;
  background: #fff;
  padding: 10px 10px 0;
  border-bottom: 1px solid #ddd;
}
.bond {
  font-size: 13px;
  height: 30px;
  font-weight: 600;
}
.content ul li {
  padding: 12px;
  border-bottom: 1px solid #ddd;
}

.pic {
  margin-top: 20px;
  background: #fff;
  padding: 10px;
}
.imgbox {
  width: 100%;
  display: flex;
  overflow: auto;
}
img {
  width: 150px;
  height: 112px;
  margin: 5px;
}
</style>

